package com.yao.exception;

import com.yao.enums.ResultEnum;
import lombok.Getter;

/**
 * User: 姚宏武
 * Date: 2017/11/19
 * Time: 13:40
 * Email：401369870@qq.com
 * Description: 自定义异常
 */
@Getter
public class WeixinSellException extends RuntimeException {

    private Integer code;

    public WeixinSellException(ResultEnum resultEnum) {
        super(resultEnum.getMessage());
        this.code = resultEnum.getCode();
    }

    public WeixinSellException(Integer code, String message) {
        super(message);
        this.code = code;
    }
}
